package course;

public class Teacher extends People{
    private Course TeachCourse[];
    public Teacher(){}
    Teacher(int ID, String name, String gender) {
        this.ID = ID;
        this.Name = name;
        this.Gender = gender;
        this.TeachCourse = new Course[1];
    }
    public void addTeachCourse(Course course) {
        for(int i=0;i<this.TeachCourse.length;i++){
            if(TeachCourse[i]==null){
                TeachCourse[i]=course;
                System.out.print("开课成功");
                break;
            }
        }


    }
}
